// let a: undefined;

// const arr: number[] = [0, 1, 2, 3, 4]
// const zero: number = arr[100]
// console.log(typeof zero)

// let f: (x: number) => number 
// f = function (y) {
//   return y
// }

// let Fun:new (x: number) => number

class A {
  aaa = 231
  foo(): this {
    return this
  }
}

class B extends A {
  bbb = 123
  bar(): this {
    return this
  }
}

const b = new B()

console.log(b)

const x = b.bar().foo()

console.log(b)
